package cn.cvs.dao;

import cn.cvs.pojo.SysUser;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface SysUserMapper {
    SysUser login(@Param("account") String account,@Param("password")String password);
    SysUser selectByAccount(@Param("account") String account) throws Exception;

    int add(SysUser sysUser) throws Exception;

    List<SysUser> selectList(@Param("realName") String realName ,@Param("roleId")String roleId);
    int selectCount(@Param("realName") String realName, @Param("roleId") Integer roleId) throws Exception;

    int deleteById(@Param("id") Integer id) throws Exception;

    SysUser selectById(@Param("id") Integer id) throws Exception;

    int update(SysUser sysUser) throws Exception;

    int updatePwd(@Param("id") Integer id, @Param("password") String password) throws Exception;
}
